// 数据库管理相关接口
import request from "@/utils/request";

// 获取表信息
export function getDatBaseInfo(data) {
  return request({
    url: "/api/getDatBaseInfo",
    method: "post",
    data,
  });
}

export function getTableData(data) {
  return request({
    url: "/api/getTableData",
    method: "post",
    data,
  });
}

export function saveTableData(data) {
  return request({
    url: "/api/saveTableData",
    method: "post",
    data,
  });
}

export function deleteDatabase(data) {
  return request({
    url: "/api/deleteDatabase",
    method: "post",
    data,
  });
}

export function addDataBase(data) {
  return request({
    url: "/api/addDataBase",
    method: "post",
    data,
  });
}

export function delTableData(data) {
  return request({
    url: "/api/delTableData",
    method: "post",
    data,
  });
}

export function getServeFiles(data) {
  return request({
    url: "/api/getServeFiles",
    method: "post",
    data,
  });
}

export function addServeFile(data) {
  return request({
    url: "/api/addServeFile",
    method: "post",
    data,
  });
}

// 删除服务器文件
export function delServeFile(data) {
  return request({
    url: "/api/delServeFile",
    method: "post",
    data,
  });
}

// 修改服务器文件名称
export function editServeFile(data) {
  return request({
    url: "/api/editServeFile",
    method: "post",
    data,
  });
}

// 解压服务器 压缩文件
export function decompressionServeFile(data) {
  return request({
    url: "/api/decompressionServeFile",
    method: "post",
    data,
  });
}

// 移动服务器文件
export function moveServeFile(data) {
  return request({
    url: "/api/moveServeFile",
    method: "post",
    data,
  });
}

export function connectTerminal(data) {
  return request({
    url: "/api/connectTerminal",
    method: "post",
    data,
  });
}

// 获取git 仓库 数据
export function getGitList(data) {
  return request({
    url: "/api/getGitList",
    method: "post",
    data,
  });
}

export function sync_git(data) {
  return request({
    url: "/api/sync_git",
    method: "post",
    data,
  });
}

export function git_history_message(data) {
  return request({
    url: "/api/git_history_message",
    method: "post",
    data,
  });
}

export function git_branch_message(data) {
  return request({
    url: "/api/git_branch_message",
    method: "post",
    data,
  });
}

export function checkDiff(data) {
  return request({
    url: "/api/checkDiff",
    method: "post",
    data,
  });
}

export function commit(data) {
  return request({
    url: "/api/commit",
    method: "post",
    data,
  });
}

export function gitmanageUpdate(data) {
  return request({
    url: "/api/gitmanageUpdate",
    method: "post",
    data,
  });
}

export function gitmanageDel(data) {
  return request({
    url: "/api/gitmanageDel",
    method: "post",
    data,
  });
}



